//
//  SmallDecisionsHomeHeaderReusableView.m
//  SmallDecisions
//
//  Created by 李付雄 on 2025/8/14.
//

#import "SmallDecisionsHomeHeaderReusableView.h"

@implementation SmallDecisionsHomeHeaderReusableView
- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if(self) {
        [self createSmallDecisionsHomeHeaderReusableViewSubviewsUI];
    }
    return self;
}

- (void)createSmallDecisionsHomeHeaderReusableViewSubviewsUI {
    UIImageView *imageView = [[UIImageView alloc] init];
    imageView.contentMode = UIViewContentModeScaleAspectFit;
    imageView.image = [UIImage imageNamed:@"home_banner_img"];
    imageView.layer.cornerRadius  = 8;
    imageView.layer.masksToBounds = YES;
    [self addSubview:imageView];
    
    [imageView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.bottom.mas_offset(-5);
        make.left.mas_offset(20);
        make.right.mas_offset(-20);
        make.top.mas_offset(10);
    }];
}
@end
